package com.lms.desiginmode.builder;

import com.lms.desiginmode.builder.endpointbuilder.Endpoint;
import com.lms.desiginmode.builder.endpointbuilder.EndpointBuilder;
import lombok.Data;

/**
 * @Author: 李孟帅
 * @CreateTime: 2020-12-12 16:20
 * @Description:
 */
@Data
public class Heap implements Endpoint {
    private String name;
    private Double usage;

    public static class HeapBuilder implements EndpointBuilder {
        Heap heap=new Heap();

        public HeapBuilder name(String name){
            heap.name=name;
            return this;
        }
        public HeapBuilder usage(Double usage){
            heap.usage=usage;
            return this;
        }

        @Override
        public Heap build(){
            return  heap;
        }

    }
}
